package cn.tedu.spring.service;

import cn.tedu.spring.entity.Dept;
import cn.tedu.spring.mapper.DeptMapper;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * Author：程Sir
 * Name： framework
 * Content:
 */
@Service
public class DeptService {
    @Resource
    private DeptMapper deptMapper;

    public List<Dept> findAll(){
        return deptMapper.selectAll();
    }

    public Dept findDept(Integer id){
        return deptMapper.selectOneById(id);
    }

}
